package com.study.talk.module.service;

import com.study.talk.common.resullt.FwResult;
import com.study.talk.module.entity.GroupInfo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.study.talk.module.entity.GroupUserInfo;
import com.study.talk.module.entity.UserInfo;
import com.study.talk.module.entity.vo.GroupInfoVo;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author thor
 * @since 2023-12-18
 */
public interface GroupInfoService extends IService<GroupInfo> {
    void addGroup(GroupInfoVo groupInfoVo);

    List<GroupUserInfo> getMembers(Integer groupId);

    List<GroupInfo> getGroupListByGroupName(String groupName);

    List<GroupInfo> getGroupListByUserId(Integer userId);

    List<UserInfo> getMembersUserInfo(Integer groupId);

    FwResult<Boolean> disband(Integer userId, Integer groupId);

    void sendAcceptJoinGroupMsg(GroupInfo groupInfo, UserInfo userInfo);
}
